package com.hdax.dm.mapstucts;

import com.hdax.dm.beans.base.image;
import com.hdax.dm.dto.CarouseDto;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;

import java.util.List;

@Mapper(componentModel = "Spring")
public abstract class CarouseDtoMapper {

    @Mapping(source = "imgUrl", target = "itemName")
    public abstract CarouseDto toTarget(image source);

    public abstract List<CarouseDto> toTargetList(List<image> sources);

}
